Skip to main content

Generated Project Structure

@corva/create-app generates a complete project with the platform entrypoints, app shell, settings, tests, and build configuration already connected. Start with that structure and add folders only when the app needs them.

my-frontend-app/
├── manifest.json
├── package.json
├── config-overrides.js
├── src/
│ ├── index.js
│ ├── App.tsx
│ ├── AppSettings.tsx
│ ├── App.scss
│ ├── constants.ts
│ ├── types.ts
│ ├── assets/
│ ├── __mocks__/
│ └── __tests__/
├── .cursor/mcp.json
├── .codex/config.toml
└── .mcp.json

JavaScript projects use .js files instead of .ts and .tsx.

Files with platform responsibilities

FileResponsibilityGuidance
manifest.jsonApp identity and platform behaviorEdit supported values, but do not change the registered app key.
src/index.jsExports component and settingsPreserve the generated export shape.
src/App.tsxRoot app componentKeep AppContainer as the root app shell.
src/AppSettings.tsxSettings shown from AppHeaderStore only customer choices that should persist.
config-overrides.jsCorva development and build configurationChange only for a documented integration need.
package.jsonSupported scripts and generated dependenciesTreat the generated versions as the compatibility baseline.

The build and ZIP scripts expect the default exports in App and AppSettings. You can move most implementation code into other files, but keep these generated entrypoints.

A structure that grows with the app

For an app larger than the starter, organize by responsibility:

src/
├── App.tsx
├── AppSettings.tsx
├── components/
│ ├── AssetSummary/
│ └── DrillingChart/
├── hooks/
│ └── useDrillingData.ts
├── api/
│ └── drillingData.ts
├── utils/
├── constants/
├── types/
└── __tests__/
  • Put reusable visual units in components.
  • Put stateful React behavior in hooks.
  • Put Corva API calls in api so request construction is not mixed with rendering.
  • Keep pure transformation and formatting logic in utils.
  • Keep tests close to the behavior or in the generated __tests__ folder, but use one convention consistently.

Avoid creating empty folders just to match this example. A small app can remain mostly in App.tsx until there is a clear boundary to extract.

Segment-specific starter

The scaffolder selects the starter using application.segments:

  • A drilling app starts with rig and well handling.
  • A completion app starts with fracFleet, well, and wells handling.

After generation, both become src/App.tsx or src/App.js; the unused starter is not copied into the project.

Next, learn how those assets and settings are exposed through App Context and Settings.